package com.example.demo.config;

import com.baomidou.mybatisplus.extension.plugins.OptimisticLockerInterceptor;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * @className: com.example.demo.config-> MybatisPlusInterceptor
 * @description: 乐观锁配置类
 * @author: 刘幸
 * @createDate: 2021-04-27 15:04
 * @version: 1.0
 * @todo:
 */
@Configuration

public class MybatisPlusConfig {
    /**
     * 旧版
     */
    @Bean
    public OptimisticLockerInterceptor optimisticLockerInterceptor() {
        return new OptimisticLockerInterceptor();
    }

    /**
     * 新版
     */

}